﻿using System.Web.UI;

namespace Sex
{
    public partial class Sex : System.Web.UI.Page
    {
        public class ListExtensions : MyList
        {
            public ListExtensions(State MyState)
                : base(MyState, "File Extensions", "Extension", new string[] { "FileType", "Brush", "Template", "Mime-Type" })
            {
                for (int i = 0; i < FileTypes.list.Count; i++)
                {
                    string TemplateId = FileTypes.list[i].MediaTemplateId.ToString();
                    string Extension = FileTypes.list[i].Extension;
                    if (TemplateId == "-1") TemplateId = "";
                    Add(Extension, new string[] { FileTypes.list[i].Type.ToString(), FileTypes.list[i].brush, TemplateId, Mime.GetMimeType(Extension) });
                }
            }
        }
    }
}